package com.example.demo.niuke.huawei_b;

import java.util.Scanner;

/**
 * ******************************************************
 *
 * @author liugh9
 * @version 1.0
 * @classname _2质数因子
 * @description
 * @date 2023/08/30 21:40
 * <p>
 * ******************************************************
 */
public class _2质数因子 {

    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);

        long num = scanner.nextLong();
        long k = (long) Math.sqrt(num);

        for (long i = 2; i <= k; ++i) {
            while (num % i == 0) {
                System.out.print(i + " ");
                num /= i;
            }
        }
        System.out.println(num == 1 ? "" : num + " ");
    }
}
